package com.alipay.api.request;

import com.alipay.api.AlipayUploadRequest;
import com.alipay.api.FileItem;
import com.alipay.api.internal.util.AlipayHashMap;
import com.alipay.api.response.AlipayOfflineMaterialImageUploadResponse;
import java.util.HashMap;
import java.util.Map;

public class AlipayOfflineMaterialImageUploadRequest implements AlipayUploadRequest {

   private AlipayHashMap udfParams;
   private String apiVersion = "1.0";
   private FileItem imageContent;
   private String imageName;
   private String imageType;
   private String terminalType;
   private String terminalInfo;
   private String prodCode;
   private String notifyUrl;


   public void setImageContent(FileItem imageContent) {
      this.imageContent = imageContent;
   }

   public FileItem getImageContent() {
      return this.imageContent;
   }

   public void setImageName(String imageName) {
      this.imageName = imageName;
   }

   public String getImageName() {
      return this.imageName;
   }

   public void setImageType(String imageType) {
      this.imageType = imageType;
   }

   public String getImageType() {
      return this.imageType;
   }

   public String getNotifyUrl() {
      return this.notifyUrl;
   }

   public void setNotifyUrl(String notifyUrl) {
      this.notifyUrl = notifyUrl;
   }

   public String getApiVersion() {
      return this.apiVersion;
   }

   public void setApiVersion(String apiVersion) {
      this.apiVersion = apiVersion;
   }

   public void setTerminalType(String terminalType) {
      this.terminalType = terminalType;
   }

   public String getTerminalType() {
      return this.terminalType;
   }

   public void setTerminalInfo(String terminalInfo) {
      this.terminalInfo = terminalInfo;
   }

   public String getTerminalInfo() {
      return this.terminalInfo;
   }

   public String getProdCode() {
      return this.prodCode;
   }

   public void setProdCode(String prodCode) {
      this.prodCode = prodCode;
   }

   public String getApiMethodName() {
      return "alipay.offline.material.image.upload";
   }

   public Map getTextParams() {
      AlipayHashMap txtParams = new AlipayHashMap();
      txtParams.put("image_name", this.imageName);
      txtParams.put("image_type", this.imageType);
      if(this.udfParams != null) {
         txtParams.putAll(this.udfParams);
      }

      return txtParams;
   }

   public void putOtherTextParam(String key, String value) {
      if(this.udfParams == null) {
         this.udfParams = new AlipayHashMap();
      }

      this.udfParams.put(key, value);
   }

   public Map getFileParams() {
      HashMap params = new HashMap();
      params.put("image_content", this.imageContent);
      return params;
   }

   public Class getResponseClass() {
      return AlipayOfflineMaterialImageUploadResponse.class;
   }
}
